﻿<%@ Control Language="C#" %>
<%@ Import Namespace="Hidistro.UI.SaleSystem.Tags" %>
<ul class="p-pager">
    <li><a href="javascript:PageUp();">上一页</a></li>
    <asp:Repeater runat="server" ID="PList">
        <ItemTemplate>
            <li>
                <a id="div" class="wnxd_pager_a" runat="server" href="javascript:void(0);"></a>
            </li>
        </ItemTemplate>
    </asp:Repeater>
    <li><a href="javascript:PageDown();">下一页</a></li>
</ul>
<input runat="server" type="hidden" id="wnxd_Pager_Max" clientidmode="Static" />
<script type="text/javascript">
    function PageUp() {
        var pn = parseInt($(".p-pager a.current").text());
        if (pn > 1) {
            pn--;
            RefreshPager(pn);
        }
    }
    function PageDown() {
        var pn = parseInt($(".p-pager a.current").text());
        if (pn < parseInt($("#wnxd_Pager_Max").val())) {
            pn++;
            RefreshPager(pn);
        }
    }
    $(".p-pager a.wnxd_pager_a").click(function () {
        var pn = parseInt($(this).text());
        RefreshPager(pn);
    });
</script>
